<?php 
// +----------------------------------------------------------------------
// | RXThinkCMF框架 [ RXThinkCMF ]
// +----------------------------------------------------------------------
// | 版权所有 2017~2020 南京RXThinkCMF研发中心
// +----------------------------------------------------------------------
// | 官方网站: http://www.rxthink.cn
// +----------------------------------------------------------------------
// | Author: 牧羊人 <1175401194@qq.com>
// +----------------------------------------------------------------------

namespace app\admin\controller;


use app\admin\service\OfContractannexService;
use app\common\controller\Backend;
use think\facade\View;

/**
 * 附件管理-控制器
 * @author 牧羊人
 * @since: 2021/12/21
 * Class Ofcontractannex
 * @package app\admin\controller
 */
class Ofcontractannex extends Backend
{
    /**
     * 初始化方法
     * @author 牧羊人
     * @since: 2021/12/21
     */
    public function initialize()
    {
        parent::initialize(); // TODO: Change the autogenerated stub
        $this->model = new \app\admin\model\OfContractannex();
        $this->service = new OfcontractannexService();
    }
	
	
    /**
     * 添加或编辑
     * @return mixed
     * @throws \think\db\exception\DataNotFoundException
     * @throws \think\db\exception\DbException
     * @throws \think\db\exception\ModelNotFoundException
     * @author 牧羊人
     * @since 2020/7/2
     */
    public function edit()
    {
        // 合同列表
        $mod = new \app\admin\model\Ofcontract();
        $list = $mod->where("mark", 1)->order("id desc")->select()->toArray();
        View::assign("list", $list);

        return parent::edit(); // TODO: Change the autogenerated stub
    }

}